# 创建一个简单类
# class vTest:
#     def prt(self):
#         print(self)
#         print(self.__class__)
#
#
# t = vTest()
# t.prt()

# 创建实例对象

# class Employee:
#     '所有员工的基类'
#     empCount = 0
#
#     def __init__(self, name, salary):
#         self.name = name
#         self.salary = salary
#         Employee.empCount += 1
#
#     def displayCount(self):
#         print("Total Employee %d" , Employee.empCount)
#
#     def displayEmployee(self):
#         print( "Name : ", self.name, ", Salary: ", self.salary)
#
# "创建 Employee 类的第一个对象"
# emp1 = Employee("Zara", 2000)
# "创建 Employee 类的第二个对象"
# emp2 = Employee("Manni", 5000)
# emp1.displayEmployee()
# emp2.displayEmployee()
# # 添加age 属性
# # emp1.age = 7  # 添加一个 'age' 属性
# # emp1.age = 8  # 修改 'age' 属性
# # del emp1.age  # 删除 'age' 属性
# print("Total Employee " , Employee.empCount)


# 内置属性调用示例
class Employee:
    '所有员工的基类'
    empCount = 0

    def __init__(self, name, salary):
        self.name = name
        self.salary = salary
        Employee.empCount += 1

    def displayCount(self):
        print("Total Employee :" , Employee.empCount)


    def displayEmployee(self):
        print("Name : ", self.name, ", Salary: ", self.salary)

print("Employee.__doc__:", Employee.__doc__)
print("Employee.__name__:", Employee.__name__)
print("Employee.__module__:", Employee.__module__)
print("Employee.__bases__:", Employee.__bases__)
print("Employee.__dict__:", Employee.__dict__)
